#import "WonderYonderCell.h"


@implementation WonderYonderCell

- (instancetype)initWithFrame:(CGRect)frame {
	self = [super initWithFrame:frame];
	if (self) {
		//self.contentView.backgroundColor = UIColor.whiteColor;
	}
	return self;
}

- (void)setPonderDiligentYearling:(WonderYonderModel *)ponderDiligentYearling {
	_ponderDiligentYearling = ponderDiligentYearling;

	//: 配置cell的UI

	self.kingdomLabel.text = ponderDiligentYearling.radiantKeepsakeFlutter;

	NSString *pioneerOasisWhistle = [NSString stringWithFormat:@"%ld", ponderDiligentYearling.tranquilJoyful];
	self.blazeOasisLabel.text = pioneerOasisWhistle;

	if (ponderDiligentYearling.flourishPioneerCourageous.count > 0) {
		[self.zealKiteImageView sd_setImageWithURL:[NSURL URLWithString:ponderDiligentYearling.flourishPioneerCourageous[0]] placeholderImage:nil];
	}

}
//: vividUplift 的点击事件
- (void)action_1 {}

//: picture 的点击事件
- (void)action_2 {}

- (UITextView *)blossomSuspicionDazzleTextView {
	if (!_blossomSuspicionDazzleTextView) {
	
        _blossomSuspicionDazzleTextView = [[UITextView alloc] initWithFrame:CGRectZero];
	}
	return _blossomSuspicionDazzleTextView;
}

- (UILabel *)blazeOasisLabel {
	if (!_blazeOasisLabel) {
	
        _blazeOasisLabel = [UILabel new];
        _blazeOasisLabel.text = @"label_6";
        _blazeOasisLabel.font = [UIFont systemFontOfSize:18 weight:UIFontWeightBold];
        _blazeOasisLabel.textColor = [UIColor colorWithRed:10/255.0 green:81/255.0 blue:145/255.0 alpha:0.5];
        _blazeOasisLabel.textAlignment = NSTextAlignmentCenter;
        _blazeOasisLabel.numberOfLines = 0;
	}
	return _blazeOasisLabel;
}

- (void)dreamscapeYearnGrumpyConfigUI {

    //: 描述_0
    self.illuminatePeacefulGratitudeTextField = [[UITextField alloc] init];
    self.illuminatePeacefulGratitudeTextField.size = CGSizeMake(103, 33);
    self.illuminatePeacefulGratitudeTextField.left = 40;
    self.illuminatePeacefulGratitudeTextField.top = 1;
    [self.contentView addSubview:self.illuminatePeacefulGratitudeTextField];


    //: 描述_1
    UIButton *vividUplift = [UIButton new];
    vividUplift.frame = CGRectMake(16, 28, 80, 124);
    UIImage *freedom = [UIImage imageNamed:@"images/icon_1.png"];
    if (freedom) {
	    [vividUplift setImage:freedom forState:UIControlStateNormal];
    }
    [vividUplift setTitle:@"button_1" forState:UIControlStateNormal];
    [vividUplift setTitle:@"button_selected_1" forState:UIControlStateSelected];
    [vividUplift setTitleColor:[UIColor colorWithRed:67/255.0 green:173/255.0 blue:38/255.0 alpha:0.7] forState:UIControlStateNormal];
    [vividUplift setTitleColor:[UIColor colorWithRed:49/255.0 green:141/255.0 blue:67/255.0 alpha:0.7] forState:UIControlStateSelected];
    [vividUplift addTarget:self action:@selector(action_1) forControlEvents:UIControlEventTouchUpInside];
    self.thriveQuakeDelightfulButton = vividUplift;
    [self.contentView addSubview:vividUplift];


    //: 描述_2
    UIButton *picture = [[UIButton alloc] init];
    UIImage *cascadeRebirth = [UIImage imageNamed:@"images/icon_2.png"];
    if (cascadeRebirth) {
	    [picture setImage:cascadeRebirth forState:UIControlStateNormal];
    }
    [picture setTitle:@"button_2" forState:UIControlStateNormal];
    [picture setTitle:@"button_selected_2" forState:UIControlStateSelected];
    [picture setTitleColor:[UIColor colorWithRed:81/255.0 green:19/255.0 blue:134/255.0 alpha:0.8] forState:UIControlStateNormal];
    [picture setTitleColor:[UIColor colorWithRed:154/255.0 green:162/255.0 blue:64/255.0 alpha:0.8] forState:UIControlStateSelected];
    [picture addTarget:self action:@selector(action_2) forControlEvents:UIControlEventTouchUpInside];
    self.luminousQuiverBtn = picture;
    [self.contentView addSubview:picture];
	[self.luminousQuiverBtn mas_makeConstraints:^(MASConstraintMaker *make) {
		make.width.mas_equalTo(48);
		make.height.mas_equalTo(52);
		make.top.equalTo(@(29));
		make.bottom.equalTo(@(20));
	}];

	//: 描述_3
	[self.contentView addSubview:self.blossomSuspicionDazzleTextView];
	[self.blossomSuspicionDazzleTextView mas_makeConstraints:^(MASConstraintMaker *make) {
		make.width.mas_equalTo(33);
		make.height.mas_equalTo(183);
	}];


    //: 描述_4
    self.kingdomLabel = [[UILabel alloc] init];
    self.kingdomLabel.frame = CGRectMake(36, 39, 171, 57);
    self.kingdomLabel.text = @"label_4";
    self.kingdomLabel.font = [UIFont systemFontOfSize:15 weight:UIFontWeightRegular];
    self.kingdomLabel.textColor = [UIColor colorWithRed:166/255.0 green:15/255.0 blue:56/255.0 alpha:0.6];
    self.kingdomLabel.textAlignment = NSTextAlignmentCenter;
    self.kingdomLabel.numberOfLines = 0;
    [self.contentView addSubview:self.kingdomLabel];


    //: 描述_5
    self.hazeRiddleTextView = [[UITextView alloc] initWithFrame:CGRectZero];
    [self.contentView addSubview:self.hazeRiddleTextView];
	[self.hazeRiddleTextView mas_makeConstraints:^(MASConstraintMaker *make) {
		make.width.mas_equalTo(117);
		make.height.mas_equalTo(79);
		make.top.equalTo(@(19));
	}];

	//: 描述_6
	[self.contentView addSubview:self.blazeOasisLabel];
	[self.blazeOasisLabel mas_makeConstraints:^(MASConstraintMaker *make) {
		make.width.mas_equalTo(80);
		make.height.mas_equalTo(109);
		make.top.equalTo(@(23));
		make.bottom.equalTo(@(19));
	}];


    //: 描述_7
    UIImageView *oasisTerrain = [UIImageView new];
    oasisTerrain.contentMode = UIViewContentModeScaleAspectFill;
    oasisTerrain.clipsToBounds = YES;
    oasisTerrain.layer.cornerRadius = 0;
    oasisTerrain.layer.masksToBounds = YES;
    oasisTerrain.frame = CGRectMake(1, 36, 152, 83);
    UIImage *flutterUnveil = [UIImage imageNamed:@"images/image_7.png"];
    if (flutterUnveil) {
	    oasisTerrain.image = flutterUnveil;
    }
    self.zealKiteImageView = oasisTerrain;
    [self.contentView addSubview:oasisTerrain];
}


@end